package cn.liontalk.service.impl;

import cn.liontalk.dao.GoodsDao;
import cn.liontalk.service.GoodsService;
import cn.liontalk.vo.GoodsVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author: 周哲
 * @package: cn.liontalk.service.impl
 * @description:
 * @date: 2019/1/20 16:06
 * @version: V1.0
 */
@Service
public class GoodsServiceImpl implements GoodsService{


    @Autowired
    private GoodsDao goodsDao;

    @Override
    public List<GoodsVO> listGoodsVO() {
        return goodsDao.listGoodsVO();
    }

    /**
     * 根据ID 去获取货物详情
     *
     * @param goodsId 货物id
     * @return 货物信息
     */
    @Override
    public GoodsVO queryGoodsById(Long goodsId) {
        return  goodsDao.queryGoodsById(goodsId);
    }
}
